from django.db import models

# Create your models here.

class Teacher(models.Model):
    name=models.CharField(max_length=12)
    class Meta:
        db_table='teacher'


class Myclass(models.Model):
    numbers=models.CharField(max_length=12)
    name=models.CharField(max_length=12)
    kind=models.CharField(max_length=12)
    flag=models.BooleanField(default=True)
    update=models.DateField(auto_now_add=True)
    teacher=models.ForeignKey(Teacher,on_delete=models.CASCADE)
    class Meta:
        db_table='class'






